<%@ page language="java" import="java.util.*" pageEncoding="utf-8"%>
<%@ include file="/base/base.jsp"%>
<%@ include file="/base/database.jsp" %>
<% 
   //接收参数
    String leaveID=request.getParameter("leaveID");
   //根据参数读取数据库响应记录
   Connection conn=getConn();
   String sql="select * from sys_leave where leaveID=?";
   PreparedStatement pstmt=conn.prepareStatement(sql);
   pstmt.setString(1, leaveID);
   ResultSet rs=pstmt.executeQuery();
   String rs_leaveID ="";
   String rs_courseID  ="";
   String rs_reason  ="";
   String rs_daynum  ="";
   String rs_stuNo ="";
   String rs_applytime ="";
 
   String rs_audittime  ="";
   String rs_opinion ="";
   
   while(rs.next()){
	   
	   rs_leaveID =rs.getString("leaveID");
	   rs_courseID=rs.getString("courseID");
	   rs_reason=rs.getString("reason");
	   rs_daynum =rs.getString("daynum");
	   rs_stuNo  =rs.getString("stuNo");
	   rs_applytime=rs.getString("applytime");

	   rs_audittime =rs.getString("audittime");
	   rs_opinion  =rs.getString("opinion");
   }

%>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN">
<html>
<head>
<base href="<%=basePath%>">
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport"
	content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no" />
<meta name="renderer" content="webkit">
<title>学生添加请假</title>
<link rel="stylesheet" href="css/pintuer.css">
<link rel="stylesheet" href="css/admin.css">
<link rel="shortcut icon" href="images/logo.jpg">
<script src="js/jquery.js"></script>
<script src="js/pintuer.js"></script>

</head>

<body align="center">

<div class="panel admin-panel">
  <div class="panel-head" id="add"><strong><span class="icon-pencil-square-o"></span>学生添加请假</strong></div>
  <div class="body-content">
    <form method="post" class="form-x" action="page/instructor/leave/action_addleave.jsp" target="_parent">  
      <div class="form-group">
        <div class="label">
          <label>请假编号：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50"  value="<%=rs_leaveID %>" name="leaveID" data-validate="required:数据必填项" />
          <div class="tips"></div>
        </div>
      </div>
       <div class="form-group">
        <div class="label">
          <label>课程编号：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" value="<%=rs_courseID %>" name="courseID" data-validate="required:数据必填项" />
          <div class="tips"></div>
        </div>
      </div>
        <div class="form-group">
        <div class="label">
          <label>请假事由：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" value="<%=rs_reason %>" name="reason" data-validate="required:数据必填项" />
          <div class="tips"></div>
        </div>
      </div>
   
 	<div class="form-group">
        <div class="label">
          <label>天数：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" value="<%=rs_daynum %>" name="daynum" data-validate="required:数据必填项" />
          <div class="tips"></div>
        </div>
      </div>
      	<div class="form-group">
        <div class="label">
          <label>学号：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" value="<%=rs_stuNo %>" name="stuNo" data-validate="required:数据必填项" />
          <div class="tips"></div>
        </div>
      </div>
      	<div class="form-group">
        <div class="label">
          <label>请假时间：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" value="<%=rs_applytime %>" name="applytime" data-validate="required:数据必填项" />
          <div class="tips"></div>
        </div>
      </div>
      
        
      
         <div class="form-group">
        <div class="label">
          <label>审核时间：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" value="<%=rs_audittime %>" name="audittime" data-validate="required:数据必填项" />
          <div class="tips"></div>
        </div>
      </div>
      
      
         <div class="form-group">
        <div class="label">
          <label>审核意见：</label>
        </div>
        <div class="field">
          <input type="text" class="input w50" value="<%=rs_opinion %>" name="opinion" data-validate="required:数据必填项" />
          <div class="tips"></div>
        </div>
      </div>
      <div class="form-group">
        <div class="label">
          <label></label>
        </div>
        <div class="field">
          <button class="button bg-main icon-check-square-o" type="submit"> 提交</button>
          <button class="button bg-main icon-check-square-o" type="button" onclick="window.location.href='leave_list.jsp'" value="返回 ">返回</button>
        </div>
      </div>
    </form>
  </div>
</div>
</body>
</html>
